﻿<%@ Page Language="C#" AutoEventWireup="true" MasterPageFile="~/Frame/FrameMasterPage.master" CodeFile="User.aspx.cs" Inherits="Frame_User" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server">

    <style type="text/css">
        .style1
        {
            width: 61px;
        }
        .style2
        {
            width: 152px;
        }
        .style3
        {
            width: 168px;
        }
        .style4
        {
            width: 73px;
        }
        .style5
        {
            width: 165px;
        }
        .style6
        {
            width: 119px;
        }
        .style7
        {
            width: 79px;
        }
    </style>

</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">


<div>
  <table>
       <tr>
            <td class="style1" >
                <asp:Label ID="Label1" runat="server" Text="用户名："></asp:Label>
            </td>
            <td class="style3">
                <asp:TextBox ID="txtUserid" runat="server" style = "text-transform:uppercase"></asp:TextBox>
            </td>
            <td class="style4" >
                <asp:Label ID="Label2" runat="server" Text="用户简称："></asp:Label>
            </td>
            <td class="style5">
                <asp:TextBox ID="txtCusabbr" runat="server"></asp:TextBox>
            </td>
            <td class="style4" >
                <asp:Label ID="Label3" runat="server" Text="拥有角色："></asp:Label>
            </td>
            <td class="style7">
                <asp:DropDownList ID="ddlRole" runat="server">
                </asp:DropDownList>
            </td>
            <td class="style6">
                <asp:Button ID="btnFind" runat="server" Text="查询" CssClass="btn" onclick="btnFind_Click" 
                     />
            </td>

        </tr>
        </table>
        <table>
        <tr>
            <td colspan="5">
                <asp:Label ID="lblDataCount" runat="server" CssClass="summary"></asp:Label>
            </td>
        </tr>
        <tr>
            <td colspan="5">
                <asp:GridView ID="grdUser" runat="server" 
                    AutoGenerateColumns="False" CssClass="list" AllowPaging="True" 
                    onpageindexchanging="grdUser_PageIndexChanging"  >
                    <Columns>
                   <asp:TemplateField HeaderText="序号" >   
<ItemTemplate>   
　　　<%# Container.DataItemIndex + 1%>　</ItemTemplate>   
</asp:TemplateField>  
                        <asp:BoundField DataField="USERID" HeaderText="系统ID"  />
                        <asp:BoundField DataField="USERNAME" HeaderText="用户名"  />
                        <asp:BoundField DataField="RealName" HeaderText="用户简称" />
                         <asp:BoundField DataField="CHNNAME" HeaderText="中文全称" />
                         <asp:BoundField DataField="ADDRESS" HeaderText="公司名称" />
                         <asp:BoundField DataField="IsActive" HeaderText="是否激活" />
                         <asp:BoundField DataField="LOGDT" HeaderText="最近登录时间" />
                        
                        <asp:TemplateField HeaderText="操作">
                            <ItemTemplate>
                              <nobr>
                    
                                <asp:LinkButton ID="btnRole" runat="server"  
                                    Text="角色管理" 
                                    CommandArgument='<%# Eval("USERNAME") %>' onclick="btnRole_Click"  ></asp:LinkButton>

                            
                            </nobr>
                            </ItemTemplate>
                        </asp:TemplateField>
                    </Columns>
                </asp:GridView>
            </td>
        </tr>

         <tr>
            <td colspan="5">
                <asp:Label ID="lblMessage" runat="server" CssClass="ErrorNote" ></asp:Label>
            </td>
        </tr>
         <tr>
            <td colspan="2">
            <asp:Button ID="btnRefresh" runat="server" Text="刷新" CssClass="btn" 
                    onclick="btnRefresh_Click"   />
                
            </td>
            
            <td colspan="3" class="style2">
                <asp:Button ID="btnAdd" runat="server" Text="新增" CssClass="btn" 
                    onclick="btnAdd_Click" Visible="False" 
                     /></td>
        </tr>
    </table>
    </div>
    <asp:HiddenField ID="hidPageIndex" runat="server" Value="0" />
     <asp:HiddenField ID="hidPageCount" runat="server" />
</asp:Content>
